﻿using System.Collections.Generic;

namespace Citi.FinancePlanningAnalysis.Domain
{
    public partial class Crc
    {
        #region Mappings

        public static readonly Dictionary<string, string> ExcelColumnMappings = new Dictionary<string, string> { 
                { "[Fiscal Year]" , "[FiscalYear]" },
                { "[Accounting Period Number]" , "[AccountingPeriodNumber]" },
                { "[General Ledger Account Id]" , "[GeneralLedgerAccountId]" },
                { "[Local GL Account Id]" , "[LocalGLAccountId]" },
                { "[GOC]" , "[GOC]" },
                { "[Orig Journal Sub GL Feed Id]" , "[OrigJournalSubGLFeedId]" },
                { "[FDL Account Id]" , "[FDLAccountId]" },
                { "[PMF Acct Level 3]" , "[PMFAcctLevel3]" },
                { "[PMF Acct Level 4]" , "[PMFAcctLevel4]" },
                { "[PMF Acct Level 5]" , "[PMFAcctLevel5]" },
                { "[PMF Acct Level 6]" , "[PMFAcctLevel6]" },
                { "[PMF Acct Level 7]" , "[PMFAcctLevel7]" },
                { "[PMF Acct Level 8]" , "[PMFAcctLevel8]" },
                { "[PMF Acct Level 9]" , "[PMFAcctLevel9]" },
                { "[PMF Acct Level 10]" , "[PMFAcctLevel10]" },
                { "[PMF Acct Level 11]" , "[PMFAcctLevel11]" },
                { "[PMF Acct Level 12]" , "[PMFAcctLevel12]" },
                { "[PMF Acct Level 13]" , "[PMFAcctLevel13]" },
                { "[PMF Acct Level 14]" , "[PMFAcctLevel14]" },
                { "[PMF Acct Level 15]" , "[PMFAcctLevel15]" },
                { "[PMF Acct Level 16]" , "[PMFAcctLevel16]" },
                { "[PMF Acct Level 17]" , "[PMFAcctLevel17]" },
                { "[PMF Acct Level 18]" , "[PMFAcctLevel18]" },
                { "[PMF Acct Level 19]" , "[PMFAcctLevel19]" },
                { "[PMF Acct Level 20]" , "[PMFAcctLevel20]" },
                { "[Functional Currency Code]" , "[FunctionalCurrencyCode]" },
                { "[Transaction Currency Code]" , "[TransactionCurrencyCode]" },
                { "[Reporting Currency Code]" , "[ReportingCurrencyCode]" },
                { "[Functional CCY YTD Bal]" , "[FunctionalCCYYTDBal]" },
                { "[Reporting CCY MTD Bal]" , "[ReportingCCYMTDBal]" }
            };
        					
        #endregion

        public const string QueryMergeDate = "EXEC sp_ImportCrc";
        public const string QueryDeletePrevious = "DELETE FROM CrcTemp";

        public const string QueryExcel = @"SELECT 
                [Fiscal Year],
                [Accounting Period Number],
                [General Ledger Account Id],
                [Local GL Account Id],
                [GOC],
                [Orig Journal Sub GL Feed Id],
                [FDL Account Id],
                [PMF Acct Level 3],
                [PMF Acct Level 4],
                [PMF Acct Level 5],
                [PMF Acct Level 6],
                [PMF Acct Level 7],
                [PMF Acct Level 8],
                [PMF Acct Level 9],
                [PMF Acct Level 10],
                [PMF Acct Level 11],
                [PMF Acct Level 12],
                [PMF Acct Level 13],
                [PMF Acct Level 14],
                [PMF Acct Level 15],
                [PMF Acct Level 16],
                [PMF Acct Level 17],
                [PMF Acct Level 18],
                [PMF Acct Level 19],
                [PMF Acct Level 20],
                [Functional Currency Code],
                [Transaction Currency Code],
                [Reporting Currency Code],
                [Functional CCY YTD Bal],
                [Reporting CCY MTD Bal]
                FROM [{0}$] WHERE [Functional CCY YTD Bal] <> 0 OR [Reporting CCY MTD Bal] <> 0";
    }
}
